<%--
  Created by IntelliJ IDEA.
  User: sjy
  Date: 2023/4/17
  Time: 18:07
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<html>
<head>
    <title>登陆日志页面</title>
</head>
<body>
<table border="1px" cellpadding="10" cellspacing="0" style="margin: 0 auto">
    <tr>
        <td>序号</td>
        <td>用户名</td>
        <td>IP地址</td>
        <td>登陆时间</td>
    </tr>

    <c:forEach items="${userLog}" var="user"  varStatus="u">
    <tr>
        <td>${u.index+1}</td>
        <td>${user.name}</td>
        <td>${user.ip}</td>
        <td><fmt:formatDate value="${user.time}" pattern="yyyy-MM-dd HH:mm:ss"/></td>
    </tr>
    </c:forEach>

</table>

</body>
</html>
